package com.umeng.fb.a;

import android.content.Context;
import android.content.Intent;
import com.umeng.fb.util.a;
import com.umeng.fb.util.b;
import java.util.concurrent.Callable;
import org.json.JSONObject;

public class f
  implements Callable<Boolean>
{
  static String a = "MsgWorker";
  JSONObject b;
  Context c;

  public f(JSONObject paramJSONObject, Context paramContext)
  {
    this.b = paramJSONObject;
    this.c = paramContext;
  }

  public Boolean a()
    throws Exception
  {
    String str3;
    String str4;
    String str5;
    String str1 = this.b.optString("type");
    String str2 = this.b.optString("feedback_id");
    if ("user_reply".equals(str1))
    {
      str3 = "user_reply";
      str4 = "http://feedback.whalecloud.com/feedback/reply";
      str5 = "reply";
    }
    while (true)
    {
      JSONObject localJSONObject1;
      label60: Intent localIntent;
      try
      {
        JSONObject localJSONObject2 = a.a(str4, str5, this.b).a();
        localJSONObject1 = localJSONObject2;
        localIntent = new Intent().setAction("postFeedbackFinished").putExtra("type", str3).putExtra("feedback_id", str2);
        if (!(b.a(localJSONObject1)))
          break label171;
        b.e(this.b);
        localIntent.putExtra("PostFeedbackBroadcast", "succeed");
        label112: if (!("user_reply".equals(str1)))
          break label192;
        com.umeng.fb.util.c.b(this.c, this.b);
        label133: this.c.sendBroadcast(localIntent);
        return null;
        str3 = "new_feedback";
        str4 = "http://feedback.whalecloud.com/feedback/feedbacks";
        label171: label192: str5 = "feedback";
      }
      catch (Exception localException)
      {
        localException.printStackTrace();
        localJSONObject1 = null;
        break label60:
        b.c(this.b);
        localIntent.putExtra("PostFeedbackBroadcast", "fail");
        break label112:
        com.umeng.fb.util.c.a(this.c, "feedback", str2);
        com.umeng.fb.util.c.a(this.c, this.b);
        break label133:
      }
    }
  }
}

/* Location:           H:\360云盘\lewa_explorer_3.0\bin\FileApp_orig_dex2jar.jar
 * Qualified Name:     com.umeng.fb.a.f
 * JD-Core Version:    0.5.2
 */